home *** CD-ROM | disk | FTP | other *** search
- /* p u t w
- *
- * Write a word to a stream. The function putw returns the word written
- * or EOF on error. Because EOF is a valid word, it is better for the
- * caller to check for errors using ferror.
- *
- * Patchlevel 1.0
- *
- * Edit History:
- */
-
- #include "stdiolib.h"
-
- /*LINTLIBRARY*/
-
- int putw(w, fp)
-
- int w; /* word to write */
- FILE *fp; /* stream */
-
- {
- return fwrite((void *) &w, (unsigned int)sizeof(int), 1, fp) == 1 ? w : EOF;
- }
-